package cc.rengu.redp.flowable.bizmodel.web.service;

import cc.rengu.redp.common.domain.QueryRequest;
import cc.rengu.redp.flowable.bizmodel.db.domain.BizCfgField;
import cc.rengu.redp.flowable.bizmodel.db.domain.BizCfgModel;
import cc.rengu.redp.system.domain.User;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;
import java.util.Map;

/**
 * @author xushitang
 */
public interface BizCfgModelService extends IService<BizCfgModel> {
    IPage<BizCfgModel> findBizCfgModel(QueryRequest request, BizCfgModel bizCfgModel);

    List<BizCfgModel> findAllAvailableModels(User user);

    List<BizCfgField> findIndexedFieldsInModel(String modelId);

    List<BizCfgField> findFieldsInModel(String modelId);

    void saveBizCfgModel(BizCfgModel bizCfgModel, List<BizCfgField> bizCfgFields);

    void deleteBizCfgModel(String[] modelIds);

    Map<String, Object> getBizCfgModel(String modelId);

    Map<String, String> getAllProcesses();

    Map<String, String> getEndEvents(String procDefId);
}
